﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace MINERP.DAL.InfoConfig
{
    public  class FlowTemplateDAL:DALBase
    {
        /// <summary>
        /// Get FlowTemplate object
        /// </summary>
        /// <param name="flowTemplateId"></param>
        /// <returns></returns>
        public static Tb_FlowTemplate GetFlowTemplateObj(int flowTemplateId)
        {
            return DataEntites.Tb_FlowTemplate.First(f => f.FlowTemplateId == flowTemplateId);  
        }

        /// <summary>
        /// Delete FlowTemplate object
        /// </summary>
        /// <param name="obj"></param>
        public static void DeleteFlowTemplate(Tb_FlowTemplate obj)
        {
            DataEntites.DeleteObject(obj);
            DataEntites.SaveChanges();
        }
    }
}
